package com.nuanshui.heatedloan.baseservice.model;


import com.nuanshui.heatedloan.dal.BaseEntityImpl;
import com.nuanshui.heatedloan.enums.FileBelong;

public class Media extends BaseEntityImpl implements Comparable<Media> {

	private Integer type; // 0:文本 1:图片 2:视频 3:语音 4:html
	private Integer sortNum;//排序
	private String contentText; // 文本描述
	private Integer contentType;//类型
	private String htmlText; // html文本描述
	private String imgKey; //  图片key
	private String videoImageKey; // 视频第一帧图片Key
	private String videoKey; //  视频key
	private String voiceKey;
	private String handlerVideo;//加了水印之后的视频key
	private Integer width;	//宽
	private Integer height;	//高
	private Integer cropx;
	private Integer cropy;
	private Integer cropWidth;
	private Integer cropHeight;
	private String style;//样式数据
	private Integer bizType;//业务类型
	private String bizId;
	private Integer archive; //1被存档
	private FileBelong belong;

	//for wechat
	private String mediaId;

	public String getMediaId() {
		return mediaId;
	}

	public void setMediaId(String mediaId) {
		this.mediaId = mediaId;
	}

	public String getVideoKey() {
		return videoKey;
	}
	public void setVideoKey(String videoKey) {
		this.videoKey = videoKey;
	}
	public String getVideoImageKey() {
		return videoImageKey;
	}
	public void setVideoImageKey(String videoImageKey) {
		this.videoImageKey = videoImageKey;
	}
	public FileBelong getBelong() {
		return belong;
	}
	public void setBelong(FileBelong belong) {
		this.belong = belong;
	}
	public Integer getType() {
		return type;
	}
	public void setType(Integer type) {
		this.type = type;
	}
	public Integer getArchive() {
		return archive;
	}
	public void setArchive(Integer archive) {
		this.archive = archive;
	}
	public String getStyle() {
		return style;
	}
	public void setStyle(String style) {
		this.style = style;
	}
	public String getBizId() {
		return bizId;
	}
	public void setBizId(String bizId) {
		this.bizId = bizId;
	}
	public String getVoiceKey() {
		return voiceKey;
	}
	public void setVoiceKey(String voiceKey) {
		this.voiceKey = voiceKey;
	}
	public Integer getContentType() {
		return contentType;
	}
	public void setContentType(Integer contentType) {
		this.contentType = contentType;
	}
	public Integer getSortNum() {
		return sortNum;
	}
	public void setSortNum(Integer sortNum) {
		this.sortNum = sortNum;
	}
	public String getContentText() {
		return contentText;
	}
	public void setContentText(String contentText) {
		this.contentText = contentText;
	}	
	public String getHtmlText() {
		return htmlText;
	}
	public void setHtmlText(String htmlText) {
		this.htmlText = htmlText;
	}
	public Integer getBizType() {
		return bizType;
	}
	public void setBizType(Integer bizType) {
		this.bizType = bizType;
	}
	public String getImgKey() {
		return imgKey;
	}
	public void setImgKey(String imgKey) {
		this.imgKey = imgKey;
	}
	public String getHandlerVideo() {
		return handlerVideo;
	}
	public void setHandlerVideo(String handlerVideo) {
		this.handlerVideo = handlerVideo;
	}
	
	public Integer getWidth() {
		return width;
	}
	public void setWidth(Integer width) {
		this.width = width;
	}
	public Integer getHeight() {
		return height;
	}
	public void setHeight(Integer height) {
		this.height = height;
	}
	public Integer getCropx() {
		return cropx;
	}
	public void setCropx(Integer cropx) {
		this.cropx = cropx;
	}
	public Integer getCropy() {
		return cropy;
	}
	public void setCropy(Integer cropy) {
		this.cropy = cropy;
	}
	public Integer getCropWidth() {
		return cropWidth;
	}
	public void setCropWidth(Integer cropWidth) {
		this.cropWidth = cropWidth;
	}
	public Integer getCropHeight() {
		return cropHeight;
	}
	public void setCropHeight(Integer cropHeight) {
		this.cropHeight = cropHeight;
	}
	@Override
	public int compareTo(Media o) {	
		if(this.sortNum == null) return -1;
		if(o.sortNum == null) return 1;
		return this.sortNum-o.sortNum;
	}
	
	
	
}
